adding allow-unsafe-pr-checkout: true to CI_docstring_labeler.yml#3484
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Proposed Changes:
CI_docstring_labeler.ymlworkflow uses pull_request_target and deliberately checks out the fork's HEAD to compare docstring checksums.The recent bump of actions/checkout from v6.0.2 → v6.0.3 (commit 76f9049) introduced a new security enforcement that now blocks this unless
allow-unsafe-pr-checkout: trueis explicitly set.Why it's safe to opt in here: The workflow was already designed with this security concern in mind — the Python script is copied from the trusted base branch into $runner.temp before the fork checkout happens (step "Copy file", line 22). That script then runs on the fork's files to compute a docstring checksum. No code from the fork is ever executed; it's only read as data. No custom secrets are used either, only GITHUB_TOKEN.
How did you test it?
Notes for the reviewer
Checklist
fix:,feat:,build:,chore:,ci:,docs:,style:,refactor:,perf:,test:.